//
//  AESInterface.h
//  iHealthEHR
//
//  Created by Joseph Ayo Akinyele on 7/7/10.
//  Copyright 2010 Johns Hopkins University. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "NSData+Base64.h"
#include <math.h>
#import "openssl/aes.h"
#import "openssl/sha.h"
#import "openssl/evp.h"

#define SHA2			"sha256"
#define S_KEY_LEN_256	256

/* Description: wrapper functions to the hash and AES encryption/decryption functions
   within the openssl library (libcrypto).
 */
@interface HashInterface : NSObject {
	
@private
	EVP_MD_CTX sha2ctx;
	const EVP_MD *sha2;
	int sha2_len;
	unsigned char sha2_value[EVP_MAX_MD_SIZE];
}

-(id) init;
-(unsigned char *) compute_sha2_hash:(NSArray *) strings;

@end
